package com.cqh.recruit.utils;

import com.cqh.recruit.pojo.entity.Employee;

/**
* @Description: 
* @Author: DengHao
* @Date: 2025/10/19 16:57
*/
public class EmployeeThreadLocal {
    
    //当前线程
    private static final ThreadLocal<Employee> tl = new ThreadLocal<>();

    //绑定员工用户信息到当前线程
    public static void set(Employee employee) {
        tl.set(employee);
    }

    //获取员工用户信息
    public static Employee get() {
        return tl.get();
    }

    //删除员工用户信息
    public static void remove() {
        tl.remove();
    }
}